﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Diablo_Character_Simulator.Enumerators
{
    enum WeaponType
    {
        //General weapons
        Bow,
        Crossbow,
        OneHandedAxe,
        Dagger,
        OneHandedMace,
        Spear,
        OneHandedSword,
        TwoHandedAxe,
        TwoHandedMace,
        Polearm,
        Stave,
        TwoHandedSword,

        //Barbarian specific weapons
        OneHandedMightyWeapon = 100,
        TwoHandedMightyWeapon,

        //Demon hunter specific weapons
        OneHandedCrossbow = 200,

        //Monk specific weapons
        FistWeapon = 300,
        Daibo,

        //Witch doctor specific weapons
        CeremonialKnife = 400,

        //Wizard specific weapons
        Wand = 500
    }

    public static class WeaponTypeHelper
    {
        public static float GetWeaponSpeed(Weapons type)
        {
            switch (type)
            {
                case Weapons.Bow:
                    return 1.4f;
                case Weapons.Crossbow:
                    return 1.1f;
                case Weapons.OneHandedCrossbow:
                    return 1.6f;
                case Weapons.OneHandedAxe:
                    return 1.3f;
                case Weapons.Dagger:
                    return 1.5f;
                case Weapons.OneHandedMace:
                    return 1.2f;
                case Weapons.Spear:
                    return 1.2f;
                case Weapons.OneHandedSword:
                    return 1.4f;
                case Weapons.CeremonialKnife:
                    return 1.4f;
                case Weapons.TwoHandedAxe:
                    return 1.0f;
                case Weapons.TwoHandedMace:
                    return 0.9f;
                case Weapons.Polearm:
                    return 1.0f;
                case Weapons.Stave:
                    return 1.0f;
                case Weapons.TwoHandedSword:
                    return 1.1f;
                case Weapons.Wand:
                    return 1.4f;
                case Weapons.Daibo:
                    return 1.1f;
                case Weapons.FistWeapon:
                    return 1.4f;
                case Weapons.OneHandedMightyWeapon:
                    return 1.3f;
                case Weapons.TwoHandedMightyWeapon:
                    return 1.0f;
                default:
                    throw new ArgumentException("Invalid weapon type.");
            }
        }
    }
}
